package com.oocl.euc.core.maintenance.service;

import com.oocl.euc.core.maintenance.model.Category;
import com.oocl.euc.core.maintenance.repository.CategoryRepository;
import com.oocl.euc.framework.base.persistence.IBaseRepository;
import com.oocl.euc.framework.base.service.BaseService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

@Service
public class CategoryService extends BaseService<Category, String> {
    @Autowired
    CategoryRepository categoryRepository;

    @Override
    protected IBaseRepository<Category, String> getRepository() {
        return categoryRepository;
    }

    public Category findByCategoryId(String categoryId) {
        return categoryRepository.findByCategoryId(categoryId);
    }
}
